#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>
char* left_reverse(char* buf1,int i)
{
	int count = 0;
	while (*buf1)
	{
		buf1++;
		count++;
	}
	buf1 += count;
	char tmp = *buf1;
	int k = 0;
	for (k = 0; k < count; k++)
	{
		*(buf1 - 1) = *buf1;
		buf1--;
	}
	printf("%s", buf1);
	return 0;
}
int is_left_reverse(char* arr2, char* arr1)
{
	int count = 0;
	while (*arr1)
	{
		arr1++;
		count++;
	}
	int i = 0;
	for (i = 0; i < count; i++)
	{
		left_reverse(arr1, i);
	}
	return 0;
}
int main()
{
	char arr1[10] = "ABCDEF";
	char arr2[10] = { 0 };
	scanf("%s", arr2);
	is_left_reverse(arr2, arr1);
	//is_right_reverse(arr2, arr1);
	return 0;
}
